﻿// Admin.NET 项目的版权、商标、专利和其他相关权利均受相应法律法规的保护。使用本项目应遵守相关法律法规和许可证的要求。
//
// 本项目主要遵循 MIT 许可证和 Apache 许可证（版本 2.0）进行分发和使用。许可证位于源代码树根目录中的 LICENSE-MIT 和 LICENSE-APACHE 文件。
//
// 不得利用本项目从事危害国家安全、扰乱社会秩序、侵犯他人合法权益等法律法规禁止的活动！任何基于本项目二次开发而产生的一切法律纠纷和责任，我们不承担任何责任！

using Admin.NET.Core;
using System.ComponentModel.DataAnnotations;
using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Excel;

namespace Admin.NET.Application;

/// <summary>
/// 供应商表基础输入参数
/// </summary>
public class SyssupplierBaseInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    public virtual long? Id { get; set; }
    
    /// <summary>
    /// 供应商编码
    /// </summary>
    [Required(ErrorMessage = "供应商编码不能为空")]
    public virtual string Code { get; set; }
    
    /// <summary>
    /// 供应商名称
    /// </summary>
    [Required(ErrorMessage = "供应商名称不能为空")]
    public virtual string Name { get; set; }
    
    /// <summary>
    /// 所属行业
    /// </summary>
    public virtual string? Industry { get; set; }
    
    /// <summary>
    /// 供应商分类
    /// </summary>
    public virtual string? Category { get; set; }
    
    /// <summary>
    /// 联系人
    /// </summary>
    public virtual string? ContactPerson { get; set; }
    
    /// <summary>
    /// 联系电话
    /// </summary>
    public virtual string? ContactPhone { get; set; }
    
    /// <summary>
    /// 电子邮箱
    /// </summary>
    public virtual string? Email { get; set; }
    
    /// <summary>
    /// 进货部门Id
    /// </summary>
    public virtual long? PurchasingDepartmentId { get; set; }
    
    /// <summary>
    /// 进货部门
    /// </summary>
    public virtual string? PurchasingDepartment { get; set; }
    
    /// <summary>
    /// 进货负责人Id
    /// </summary>
    public virtual long? PurchasingManagerId { get; set; }
    
    /// <summary>
    /// 进货负责人
    /// </summary>
    public virtual string? PurchasingManager { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    [Required(ErrorMessage = "状态不能为空")]
    public virtual int? Status { get; set; }
    
    /// <summary>
    /// 供应商地址
    /// </summary>
    public virtual string? Address { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public virtual string? Remarks { get; set; }
    
    /// <summary>
    /// 账户名称
    /// </summary>
    public virtual string? AccountName { get; set; }
    
    /// <summary>
    /// 纳税人识别号
    /// </summary>
    public virtual string? TaxpayerId { get; set; }
    
    /// <summary>
    /// 银行账户
    /// </summary>
    public virtual string? BankAccount { get; set; }
    
    /// <summary>
    /// 开户银行
    /// </summary>
    public virtual string? OpeningBank { get; set; }
    
    /// <summary>
    /// 开户行地址
    /// </summary>
    public virtual string? OpeningBankAddress { get; set; }
    
    /// <summary>
    /// 软删除时间
    /// </summary>
    public virtual DateTime? DeleteTime { get; set; }
    
}

/// <summary>
/// 供应商表分页查询输入参数
/// </summary>
public class PageSyssupplierInput : BasePageInput
{
    /// <summary>
    /// 供应商编码
    /// </summary>
    public string Code { get; set; }
    
    /// <summary>
    /// 供应商名称
    /// </summary>
    public string Name { get; set; }
    
    /// <summary>
    /// 所属行业
    /// </summary>
    public string? Industry { get; set; }
    
    /// <summary>
    /// 供应商分类
    /// </summary>
    public string? Category { get; set; }
    
    /// <summary>
    /// 联系人
    /// </summary>
    public string? ContactPerson { get; set; }
    
    /// <summary>
    /// 联系电话
    /// </summary>
    public string? ContactPhone { get; set; }
    
    /// <summary>
    /// 电子邮箱
    /// </summary>
    public string? Email { get; set; }
    
    /// <summary>
    /// 进货部门Id
    /// </summary>
    public long? PurchasingDepartmentId { get; set; }
    
    /// <summary>
    /// 进货部门
    /// </summary>
    public string? PurchasingDepartment { get; set; }
    
    /// <summary>
    /// 进货负责人Id
    /// </summary>
    public long? PurchasingManagerId { get; set; }
    
    /// <summary>
    /// 进货负责人
    /// </summary>
    public string? PurchasingManager { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    public int? Status { get; set; }
    
    /// <summary>
    /// 供应商地址
    /// </summary>
    public string? Address { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    public string? Remarks { get; set; }
    
    /// <summary>
    /// 账户名称
    /// </summary>
    public string? AccountName { get; set; }
    
    /// <summary>
    /// 纳税人识别号
    /// </summary>
    public string? TaxpayerId { get; set; }
    
    /// <summary>
    /// 银行账户
    /// </summary>
    public string? BankAccount { get; set; }
    
    /// <summary>
    /// 开户银行
    /// </summary>
    public string? OpeningBank { get; set; }
    
    /// <summary>
    /// 开户行地址
    /// </summary>
    public string? OpeningBankAddress { get; set; }
    
    /// <summary>
    /// 软删除时间范围
    /// </summary>
     public DateTime?[] DeleteTimeRange { get; set; }
    
    /// <summary>
    /// 选中主键列表
    /// </summary>
     public List<long> SelectKeyList { get; set; }
}

/// <summary>
/// 供应商表增加输入参数
/// </summary>
public class AddSyssupplierInput
{
    /// <summary>
    /// 供应商编码
    /// </summary>
    [Required(ErrorMessage = "供应商编码不能为空")]
    [MaxLength(50, ErrorMessage = "供应商编码字符长度不能超过50")]
    public string Code { get; set; }
    
    /// <summary>
    /// 供应商名称
    /// </summary>
    [Required(ErrorMessage = "供应商名称不能为空")]
    [MaxLength(100, ErrorMessage = "供应商名称字符长度不能超过100")]
    public string Name { get; set; }
    
    /// <summary>
    /// 所属行业
    /// </summary>
    [MaxLength(50, ErrorMessage = "所属行业字符长度不能超过50")]
    public string? Industry { get; set; }
    
    /// <summary>
    /// 供应商分类
    /// </summary>
    [MaxLength(50, ErrorMessage = "供应商分类字符长度不能超过50")]
    public string? Category { get; set; }
    
    /// <summary>
    /// 联系人
    /// </summary>
    [MaxLength(50, ErrorMessage = "联系人字符长度不能超过50")]
    public string? ContactPerson { get; set; }
    
    /// <summary>
    /// 联系电话
    /// </summary>
    [MaxLength(20, ErrorMessage = "联系电话字符长度不能超过20")]
    public string? ContactPhone { get; set; }
    
    /// <summary>
    /// 电子邮箱
    /// </summary>
    [MaxLength(100, ErrorMessage = "电子邮箱字符长度不能超过100")]
    public string? Email { get; set; }
    
    /// <summary>
    /// 进货部门Id
    /// </summary>
    public long? PurchasingDepartmentId { get; set; }
    
    /// <summary>
    /// 进货部门
    /// </summary>
    [MaxLength(50, ErrorMessage = "进货部门字符长度不能超过50")]
    public string? PurchasingDepartment { get; set; }
    
    /// <summary>
    /// 进货负责人Id
    /// </summary>
    public long? PurchasingManagerId { get; set; }
    
    /// <summary>
    /// 进货负责人
    /// </summary>
    [MaxLength(50, ErrorMessage = "进货负责人字符长度不能超过50")]
    public string? PurchasingManager { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    [Required(ErrorMessage = "状态不能为空")]
    public int? Status { get; set; }
    
    /// <summary>
    /// 供应商地址
    /// </summary>
    [MaxLength(200, ErrorMessage = "供应商地址字符长度不能超过200")]
    public string? Address { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [MaxLength(255, ErrorMessage = "备注字符长度不能超过255")]
    public string? Remarks { get; set; }
    
    /// <summary>
    /// 账户名称
    /// </summary>
    [MaxLength(100, ErrorMessage = "账户名称字符长度不能超过100")]
    public string? AccountName { get; set; }
    
    /// <summary>
    /// 纳税人识别号
    /// </summary>
    [MaxLength(50, ErrorMessage = "纳税人识别号字符长度不能超过50")]
    public string? TaxpayerId { get; set; }
    
    /// <summary>
    /// 银行账户
    /// </summary>
    [MaxLength(50, ErrorMessage = "银行账户字符长度不能超过50")]
    public string? BankAccount { get; set; }
    
    /// <summary>
    /// 开户银行
    /// </summary>
    [MaxLength(100, ErrorMessage = "开户银行字符长度不能超过100")]
    public string? OpeningBank { get; set; }
    
    /// <summary>
    /// 开户行地址
    /// </summary>
    [MaxLength(200, ErrorMessage = "开户行地址字符长度不能超过200")]
    public string? OpeningBankAddress { get; set; }
    
    /// <summary>
    /// 软删除时间
    /// </summary>
    public DateTime? DeleteTime { get; set; }
    
}

/// <summary>
/// 供应商表删除输入参数
/// </summary>
public class DeleteSyssupplierInput
{
    /// <summary>
    /// 主键Id
    /// </summary>
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
}

/// <summary>
/// 供应商表更新输入参数
/// </summary>
public class UpdateSyssupplierInput
{
    /// <summary>
    /// 主键Id
    /// </summary>    
    [Required(ErrorMessage = "主键Id不能为空")]
    public long? Id { get; set; }
    
    /// <summary>
    /// 供应商编码
    /// </summary>    
    [Required(ErrorMessage = "供应商编码不能为空")]
    [MaxLength(50, ErrorMessage = "供应商编码字符长度不能超过50")]
    public string Code { get; set; }
    
    /// <summary>
    /// 供应商名称
    /// </summary>    
    [Required(ErrorMessage = "供应商名称不能为空")]
    [MaxLength(100, ErrorMessage = "供应商名称字符长度不能超过100")]
    public string Name { get; set; }
    
    /// <summary>
    /// 所属行业
    /// </summary>    
    [MaxLength(50, ErrorMessage = "所属行业字符长度不能超过50")]
    public string? Industry { get; set; }
    
    /// <summary>
    /// 供应商分类
    /// </summary>    
    [MaxLength(50, ErrorMessage = "供应商分类字符长度不能超过50")]
    public string? Category { get; set; }
    
    /// <summary>
    /// 联系人
    /// </summary>    
    [MaxLength(50, ErrorMessage = "联系人字符长度不能超过50")]
    public string? ContactPerson { get; set; }
    
    /// <summary>
    /// 联系电话
    /// </summary>    
    [MaxLength(20, ErrorMessage = "联系电话字符长度不能超过20")]
    public string? ContactPhone { get; set; }
    
    /// <summary>
    /// 电子邮箱
    /// </summary>    
    [MaxLength(100, ErrorMessage = "电子邮箱字符长度不能超过100")]
    public string? Email { get; set; }
    
    /// <summary>
    /// 进货部门Id
    /// </summary>    
    public long? PurchasingDepartmentId { get; set; }
    
    /// <summary>
    /// 进货部门
    /// </summary>    
    [MaxLength(50, ErrorMessage = "进货部门字符长度不能超过50")]
    public string? PurchasingDepartment { get; set; }
    
    /// <summary>
    /// 进货负责人Id
    /// </summary>    
    public long? PurchasingManagerId { get; set; }
    
    /// <summary>
    /// 进货负责人
    /// </summary>    
    [MaxLength(50, ErrorMessage = "进货负责人字符长度不能超过50")]
    public string? PurchasingManager { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>    
    [Required(ErrorMessage = "状态不能为空")]
    public int? Status { get; set; }
    
    /// <summary>
    /// 供应商地址
    /// </summary>    
    [MaxLength(200, ErrorMessage = "供应商地址字符长度不能超过200")]
    public string? Address { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>    
    [MaxLength(255, ErrorMessage = "备注字符长度不能超过255")]
    public string? Remarks { get; set; }
    
    /// <summary>
    /// 账户名称
    /// </summary>    
    [MaxLength(100, ErrorMessage = "账户名称字符长度不能超过100")]
    public string? AccountName { get; set; }
    
    /// <summary>
    /// 纳税人识别号
    /// </summary>    
    [MaxLength(50, ErrorMessage = "纳税人识别号字符长度不能超过50")]
    public string? TaxpayerId { get; set; }
    
    /// <summary>
    /// 银行账户
    /// </summary>    
    [MaxLength(50, ErrorMessage = "银行账户字符长度不能超过50")]
    public string? BankAccount { get; set; }
    
    /// <summary>
    /// 开户银行
    /// </summary>    
    [MaxLength(100, ErrorMessage = "开户银行字符长度不能超过100")]
    public string? OpeningBank { get; set; }
    
    /// <summary>
    /// 开户行地址
    /// </summary>    
    [MaxLength(200, ErrorMessage = "开户行地址字符长度不能超过200")]
    public string? OpeningBankAddress { get; set; }
    
    /// <summary>
    /// 软删除时间
    /// </summary>    
    public DateTime? DeleteTime { get; set; }
    
}

/// <summary>
/// 供应商表主键查询输入参数
/// </summary>
public class QueryByIdSyssupplierInput : DeleteSyssupplierInput
{
}

/// <summary>
/// 供应商表数据导入实体
/// </summary>
[ExcelImporter(SheetIndex = 1, IsOnlyErrorRows = true)]
public class ImportSyssupplierInput : BaseImportInput
{
    /// <summary>
    /// 供应商编码
    /// </summary>
    [ImporterHeader(Name = "*供应商编码")]
    [ExporterHeader("*供应商编码", Format = "", Width = 25, IsBold = true)]
    public string Code { get; set; }
    
    /// <summary>
    /// 供应商名称
    /// </summary>
    [ImporterHeader(Name = "*供应商名称")]
    [ExporterHeader("*供应商名称", Format = "", Width = 25, IsBold = true)]
    public string Name { get; set; }
    
    /// <summary>
    /// 所属行业
    /// </summary>
    [ImporterHeader(Name = "所属行业")]
    [ExporterHeader("所属行业", Format = "", Width = 25, IsBold = true)]
    public string? Industry { get; set; }
    
    /// <summary>
    /// 供应商分类
    /// </summary>
    [ImporterHeader(Name = "供应商分类")]
    [ExporterHeader("供应商分类", Format = "", Width = 25, IsBold = true)]
    public string? Category { get; set; }
    
    /// <summary>
    /// 联系人
    /// </summary>
    [ImporterHeader(Name = "联系人")]
    [ExporterHeader("联系人", Format = "", Width = 25, IsBold = true)]
    public string? ContactPerson { get; set; }
    
    /// <summary>
    /// 联系电话
    /// </summary>
    [ImporterHeader(Name = "联系电话")]
    [ExporterHeader("联系电话", Format = "", Width = 25, IsBold = true)]
    public string? ContactPhone { get; set; }
    
    /// <summary>
    /// 电子邮箱
    /// </summary>
    [ImporterHeader(Name = "电子邮箱")]
    [ExporterHeader("电子邮箱", Format = "", Width = 25, IsBold = true)]
    public string? Email { get; set; }
    
    /// <summary>
    /// 进货部门Id
    /// </summary>
    [ImporterHeader(Name = "进货部门Id")]
    [ExporterHeader("进货部门Id", Format = "", Width = 25, IsBold = true)]
    public long? PurchasingDepartmentId { get; set; }
    
    /// <summary>
    /// 进货部门
    /// </summary>
    [ImporterHeader(Name = "进货部门")]
    [ExporterHeader("进货部门", Format = "", Width = 25, IsBold = true)]
    public string? PurchasingDepartment { get; set; }
    
    /// <summary>
    /// 进货负责人Id
    /// </summary>
    [ImporterHeader(Name = "进货负责人Id")]
    [ExporterHeader("进货负责人Id", Format = "", Width = 25, IsBold = true)]
    public long? PurchasingManagerId { get; set; }
    
    /// <summary>
    /// 进货负责人
    /// </summary>
    [ImporterHeader(Name = "进货负责人")]
    [ExporterHeader("进货负责人", Format = "", Width = 25, IsBold = true)]
    public string? PurchasingManager { get; set; }
    
    /// <summary>
    /// 状态
    /// </summary>
    [ImporterHeader(Name = "*状态")]
    [ExporterHeader("*状态", Format = "", Width = 25, IsBold = true)]
    public int? Status { get; set; }
    
    /// <summary>
    /// 供应商地址
    /// </summary>
    [ImporterHeader(Name = "供应商地址")]
    [ExporterHeader("供应商地址", Format = "", Width = 25, IsBold = true)]
    public string? Address { get; set; }
    
    /// <summary>
    /// 备注
    /// </summary>
    [ImporterHeader(Name = "备注")]
    [ExporterHeader("备注", Format = "", Width = 25, IsBold = true)]
    public string? Remarks { get; set; }
    
    /// <summary>
    /// 账户名称
    /// </summary>
    [ImporterHeader(Name = "账户名称")]
    [ExporterHeader("账户名称", Format = "", Width = 25, IsBold = true)]
    public string? AccountName { get; set; }
    
    /// <summary>
    /// 纳税人识别号
    /// </summary>
    [ImporterHeader(Name = "纳税人识别号")]
    [ExporterHeader("纳税人识别号", Format = "", Width = 25, IsBold = true)]
    public string? TaxpayerId { get; set; }
    
    /// <summary>
    /// 银行账户
    /// </summary>
    [ImporterHeader(Name = "银行账户")]
    [ExporterHeader("银行账户", Format = "", Width = 25, IsBold = true)]
    public string? BankAccount { get; set; }
    
    /// <summary>
    /// 开户银行
    /// </summary>
    [ImporterHeader(Name = "开户银行")]
    [ExporterHeader("开户银行", Format = "", Width = 25, IsBold = true)]
    public string? OpeningBank { get; set; }
    
    /// <summary>
    /// 开户行地址
    /// </summary>
    [ImporterHeader(Name = "开户行地址")]
    [ExporterHeader("开户行地址", Format = "", Width = 25, IsBold = true)]
    public string? OpeningBankAddress { get; set; }
    
    /// <summary>
    /// 软删除时间
    /// </summary>
    [ImporterHeader(Name = "软删除时间")]
    [ExporterHeader("软删除时间", Format = "", Width = 25, IsBold = true)]
    public DateTime? DeleteTime { get; set; }
    
}
